package com.lulu.baselib.dialog;

import android.view.View;
import android.widget.TextView;

import com.lulu.baselib.R;
import com.lulu.baselib.util.StringUtil;

import butterknife.BindView;

/**
 * Author: XuChang
 * Date: 2019/10/27 1:25
 * Email: 123286473@qq.com
 * Description:
 * History:
 */
public class LoadingDialog extends BaseDialogFragment {
    @BindView(R.id.tvMsg)
    TextView tvMsg;
    String msg;

    public LoadingDialog(String msg) {
        this.msg = msg;
    }

    public LoadingDialog() {
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    @Override
    protected int getLayoutId() {
        return R.layout.dialog_loading;
    }

    @Override
    protected void initView(View view) {
        if (StringUtil.isNotEmpty(msg))
            tvMsg.setText(msg);
    }
}
